How I Solved a Security Problem in My Word Game

Hi everyone, I wanted to share a recent challenge I faced while working on my “Word Game” project and how I was able to overcome it.

While setting up the backend for my game on an AWS EC2 instance, I hit a few obstacles. Everything seemed to be running smoothly until I tried accessing my backend from the frontend, That’s when I encountered a mixed content error. Basically, my frontend was served over HTTPS, but I was trying to connect to the backend over HTTP.

At first, I wasn’t sure what was going wrong. After looking into the console, I found the issue, the backend needed to be secured with HTTPS. To solve it, I set up NGINX as a reverse proxy and created a DNS record, “apiwordgame.aidenkiettran”. I then used AWS Certificate Manager to issue an SSL certificate for that specific domain record, securing the connection. After configuring everything and updating my DNS settings, the error disappeared, and everything worked perfectly.


LinkedIn post link: